package com.novax.ex.activity.open.api;

import com.novax.ex.activity.open.model.query.OperationConfigOuterQuery;
import com.novax.ex.activity.open.model.response.OperationConfigExpandResponse;
import com.novax.ex.activity.open.model.response.OperationConfigOuterResponse;
import com.novax.ex.common.results.ReturnResult;
import com.novax.ex.common.util.PageUtil;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springdoc.core.annotations.ParameterObject;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;


import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestParam;



/**
 * @Description 后台-活动落地页
 * @Author ChenXi
 * @Date 2023/04/18/10:48
 */
@Tag(name = "前台-活动落地页", description = "前台-活动落地页")
@FeignClient(url = "${remote.activity-service.endpoint}", name = "OperationConfigApi", contextId = "OperationConfigApi")
public interface OperationConfigApi {

    @Operation(summary = "分页查询")
    @GetMapping("/v3/public/operation/config")
    ReturnResult<PageUtil<OperationConfigOuterResponse>> page(@RequestHeader("language") String language,
                                                              @ParameterObject OperationConfigOuterQuery query);


    @Operation(summary = "查询")
    @GetMapping("/v3/public/operation/config/find")
    ReturnResult<OperationConfigExpandResponse> find(@RequestHeader("language") String language,
                                                     @RequestParam String customId);

    @Operation(summary = "查询(对应语言查询不到仍会返回)")
    @GetMapping("/v3/public/operation/config/new-find")
    ReturnResult<OperationConfigExpandResponse> findIgnoreLan(@RequestHeader("language") String language,
                                                              @RequestParam String customId);

}
